import Vue from 'vue'
import Vuex from 'vuex'

Vue.use(Vuex)

export default new Vuex.Store({
    state: {
        cityList: [],
        userInfo: {}
    },
    mutations: {
        setCityList(state, payload) {
            state.cityList = payload
        },
        setUserInfo(state, payload) {
            state.userInfo = {...state.userInfo, ...payload }
        }
    },
    actions: {},
    modules: {}
})